package br.usp.wta.validator;

import java.io.IOException;

import br.usp.language.syntax.grammar.ContextFreeGrammar;
import br.usp.language.syntax.grammar.GrammarLoader;

public class GrammarProvider {

    public static final String LUFTGRAMMAR = "resources/gramatica_luft2.txt";
    public static final String INFEREDGRAMMAR = "resources/inferedgrammar.txt";

    public static ContextFreeGrammar getGrammar() throws IOException {
        
        return GrammarLoader.load(LUFTGRAMMAR); // default
    }

    public static ContextFreeGrammar getGrammar(String grammar) throws IOException {
        
        return GrammarLoader.load(grammar);
    }

}
